function search(){
	window.location.href = "search.php?action=search&k="+urlEncode(E("keyword").value)+"&fid="+getMultipleValue(E("fid"))+"&area="+E("area").value+"&topictypestr="+getRadioValue("topictypestr")+"&topicspc="+getRadioValue("topicspc")+"&starttime="+E("starttime").value+"&stoptime="+E("stoptime").value;
}
function checkKeyPressEnter(eventobject){
	var eve=eventobject||window.event;
	if(eve.keyCode==13) {
		search();
	}
}

function changeFolder(obj){
	obj.className=obj.className=='folder_0' ? 'folder_1' : 'folder_0';
	E("search_cond_div").style.height= obj.className=='folder_1'?'350px':'0px';
	E("search_cond_change").style.height= obj.className!='folder_1'?'30px':'0px';
}

function search_InitPage(){
	if(E("keyword")){E("keyword").onkeyup = function(event){checkKeyPressEnter(event);};}
	if(E("starttime")){E("starttime").onfocus = function(){choosedate.dfd(E('starttime'))};};
	if(E("stoptime")){E("stoptime").onfocus = function(){choosedate.dfd(E('stoptime'))};};
	if(action==""){
			changeFolder(E("folder_cond"));
			E("keyword").focus();
	}
	var ts=fid.split(",");
	for(var i=0;i<ts.length;i++){
		setSelect("fid",ts[i]);
	}
	setSelect("area",area);
	setRadioCheck("topictypestr",topictypestr);
	setRadioCheck("topicspc",topicspc);
}